/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package org.me.entityBeans;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author Administrador
 */
@Entity
@Table(name = "T_CILINDRADA_VEHICULOS")
@XmlRootElement
@NamedQueries({
    @NamedQuery(name = "TCilindradaVehiculos.findAll", query = "SELECT t FROM TCilindradaVehiculos t"),
    @NamedQuery(name = "TCilindradaVehiculos.findByNIdCilindradaVehiculoPk", query = "SELECT t FROM TCilindradaVehiculos t WHERE t.nIdCilindradaVehiculoPk = :nIdCilindradaVehiculoPk"),
    @NamedQuery(name = "TCilindradaVehiculos.findByNDescripcionCilindrada", query = "SELECT t FROM TCilindradaVehiculos t WHERE t.nDescripcionCilindrada = :nDescripcionCilindrada")})
public class TCilindradaVehiculos implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @Basic(optional = false)
    @Column(name = "N_ID_CILINDRADA_VEHICULO_PK")
    private Short nIdCilindradaVehiculoPk;
    @Basic(optional = false)
    @Column(name = "N_DESCRIPCION_CILINDRADA")
    private int nDescripcionCilindrada;

    public TCilindradaVehiculos() {
    }

    public TCilindradaVehiculos(Short nIdCilindradaVehiculoPk) {
        this.nIdCilindradaVehiculoPk = nIdCilindradaVehiculoPk;
    }

    public TCilindradaVehiculos(Short nIdCilindradaVehiculoPk, int nDescripcionCilindrada) {
        this.nIdCilindradaVehiculoPk = nIdCilindradaVehiculoPk;
        this.nDescripcionCilindrada = nDescripcionCilindrada;
    }

    public Short getNIdCilindradaVehiculoPk() {
        return nIdCilindradaVehiculoPk;
    }

    public void setNIdCilindradaVehiculoPk(Short nIdCilindradaVehiculoPk) {
        this.nIdCilindradaVehiculoPk = nIdCilindradaVehiculoPk;
    }

    public int getNDescripcionCilindrada() {
        return nDescripcionCilindrada;
    }

    public void setNDescripcionCilindrada(int nDescripcionCilindrada) {
        this.nDescripcionCilindrada = nDescripcionCilindrada;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (nIdCilindradaVehiculoPk != null ? nIdCilindradaVehiculoPk.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof TCilindradaVehiculos)) {
            return false;
        }
        TCilindradaVehiculos other = (TCilindradaVehiculos) object;
        if ((this.nIdCilindradaVehiculoPk == null && other.nIdCilindradaVehiculoPk != null) || (this.nIdCilindradaVehiculoPk != null && !this.nIdCilindradaVehiculoPk.equals(other.nIdCilindradaVehiculoPk))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "org.me.entityBeans.TCilindradaVehiculos[ nIdCilindradaVehiculoPk=" + nIdCilindradaVehiculoPk + " ]";
    }
    
}
